//
//  BaseTableViewController.swift
//  wei
//
//  Created by 江齐松 on 15/7/29.
//  Copyright © 2015年 江齐松. All rights reserved.
//

import UIKit

class BaseTableViewController: UITableViewController,visitlogindelegate {
    

    
    var visitview = VistorLoginView()
    var userlogon = false
    override func loadView() {
    userlogon ? super.loadView() : setupVisitorView()
    }
    


    private func setupVisitorView(){
        visitview = VistorLoginView()
        view = visitview
        visitview.delegate = self//为什么没有问号？？？？

        navigationItem.leftBarButtonItem = UIBarButtonItem(title: "注册", style: UIBarButtonItemStyle.Plain, target: nil, action: nil)
        navigationItem.rightBarButtonItem = UIBarButtonItem(title: "返回", style: UIBarButtonItemStyle.Plain, target: nil, action: nil)
}

    func login() {
        print("hh")
    }
}